package com.liuda066.forumssm.model;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

@ApiModel("帖子类")
@Data
public class Article {

    @ApiModelProperty("帖子ID")
    private Long id;

    @ApiModelProperty("板块ID")
    private Long boardId;

    @ApiModelProperty("用户ID")
    private Long userId;

    @ApiModelProperty("主题")
    private String title;

    @ApiModelProperty("查看数量")
    private Integer visitCount;

    @ApiModelProperty("回复数量")
    private Integer replyCount;

    @ApiModelProperty("点赞数")
    private Integer likeCount;

    @ApiModelProperty("状态 0 正常  1 禁言")
    private Byte state;

    @ApiModelProperty("删除状态  0 正常 1 删除")
    private Byte deleteState;

    @ApiModelProperty("创建时间")
    private Date createTime;

    @ApiModelProperty("更新时间")
    private Date updateTime;

    @ApiModelProperty("文章内容")
    private String content;

    @ApiModelProperty("板块信息")
    private Board board;

    @ApiModelProperty("用户信息")
    private User user;

    @ApiModelProperty("作者是否为自己")
    // 当作者是自己的时候，设置为true
    private Boolean own;
}